import request from '@/utils/request'

export default{
    // 1.分页查询banner
    getAllBanner(page,limit,bannerQuery){
        return request({
            url: `/educms/crm-banneradmin/pageBanner/${page}/${limit}`,
            method: 'post',
            data: bannerQuery
          })
    },

    // 2.新增banner
    addBanner(banner){
        return request({
            url: `/educms/crm-banneradmin/addBanner`,
            method: 'post',
            data: banner
          })
    },

    // 3.回显banner
    getBanner(id){
        return request({
            url: `/educms/crm-banneradmin/get/${id}`,
            method: 'get',
          })
    },

    // 4.修改banner
    updateBanner(banner){
        return request({
            url: `/educms/crm-banneradmin/update`,
            method: 'put',
            data: banner
          })
    },

    // 5.删除banner
    deleteBanner(id){
        return request({
            url: `/educms/crm-banneradmin/remove/${id}`,
            method: 'delete',
          })
    },
}